// 安装 @reduxjs/toolkit (RTK)   toolkit 工具
// 导入
import {configureStore} from '@reduxjs/toolkit'
import countReducer from './features/countSlice';
import zanReducer from './features/zanSlice';
import todoReducer from './features/todoSlice';

// 创建 store 对象
let store = configureStore({
  //合并 reducer 直接设置为对象即可
  reducer: {
    count: countReducer,
    zan: zanReducer,
    todo: todoReducer
  }
});

//暴露 store 对象
export default store;

